<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <script src="https://cdn.staticfile.org/vue/3.0.5/vue.global.js"></script>
</head>

<body>
    <div id="app" class="demo">
        <hr>
        <one></one>
        <hr>
        <two></two>
    </div>

    <template id="one">
        one----------姓名：{{name}} ,年龄：{{age}}
        <div style="color: blue;">哈哈哈哈哈哈哈哈哈</div>
    </template>
    <template id="two">
        two----------姓名：{{name}} ,年龄：{{age}}
        <div style="color: red;">嘿嘿嘿嘿嘿嘿嘿嘿嘿</div>
    </template>
</body>
<script>

    const oneConfig = {
        template:'#one',

    };
    const twoConfig = {
        template:'#two',

    };

    const HelloVueApp = {
        data() {
            return {

            }
        },
        components:{
            one:oneConfig,
            two:twoConfig
        }
    }
    Vue.createApp(HelloVueApp).mount('#app')
</script>

</html>